import { Router } from 'express'
import { AIModelController } from '../controllers/aiModel.controller'
import { authMiddleware } from '../middleware/auth'

const router = Router()
const aiModelController = new AIModelController()

// 所有路由都需要认证
router.use(authMiddleware)

router.get('/', aiModelController.getModels.bind(aiModelController))
router.post('/', aiModelController.createModel.bind(aiModelController))
router.put('/:id', aiModelController.updateModel.bind(aiModelController))
router.delete('/:id', aiModelController.deleteModel.bind(aiModelController))
router.post('/:id/default', aiModelController.setDefault.bind(aiModelController))

export default router 